using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._DataManagementTools._JoinsandRelates
{
    /// <summary>
    /// <para>Remove Relate</para>
    /// <para>Removes a relate from a feature layer or a table view.</para>
    /// <para>从要素图层或表视图中移除关联。</para>
    /// </summary>    
    [DisplayName("Remove Relate")]
    public class RemoveRelate : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public RemoveRelate()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_layer_or_view">
        /// <para>Layer Name or Table View</para>
        /// <para>The layer or table view from which to remove the relate.</para>
        /// <para>要从中移除关联的图层或表视图。</para>
        /// </param>
        public RemoveRelate(object _in_layer_or_view)
        {
            this._in_layer_or_view = _in_layer_or_view;
        }
        public override string ToolboxName => "Data Management Tools";

        public override string ToolName => "Remove Relate";

        public override string CallName => "management.RemoveRelate";

        public override List<string> AcceptEnvironments => ["workspace"];

        public override object[] ParameterInfo => [_in_layer_or_view, _relate_name, _out_layer_or_view];

        /// <summary>
        /// <para>Layer Name or Table View</para>
        /// <para>The layer or table view from which to remove the relate.</para>
        /// <para>要从中移除关联的图层或表视图。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Layer Name or Table View")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_layer_or_view { get; set; }


        /// <summary>
        /// <para>Relate Name</para>
        /// <para>The name of the relate to remove.</para>
        /// <para>要删除的相关名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Relate Name")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _relate_name { get; set; } = null;


        /// <summary>
        /// <para>Layer With Relate Removed</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Layer With Relate Removed")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public object _out_layer_or_view { get; set; }


        public RemoveRelate SetEnv(object workspace = null)
        {
            base.SetEnv(workspace: workspace);
            return this;
        }

    }

}